<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2019/1/23 0023
 * Time: 18:04
 */
namespace app\common\lib;
class Redis
{
    /**
     * 验证码前缀
     * @var string
     */
    public static $pre = "sms_";

    /**
     * 用户前缀
     * @var string
     */
    public static $userpre = 'user_';

    /**
     * 存储验证码 redis key
     * @param $phone
     * @return string
     */
    public static function smsKey($phone)
    {
        return self::$pre.$phone;
    }

    /**
     * 用户key
     * @param $phone
     * @return string
     */
    public static function userKey($phone)
    {
        return self::$userpre.$phone;
    }




}